<template>
  <div class="search-input">
    <el-input size="mini" v-model="searchValue" placeholder="搜索" @keyup.enter.native="searchTheme">
      <i slot="suffix" class="el-input__icon el-icon-search" @click="searchTheme"></i>
    </el-input>
  </div>
</template>

<script>
  export default {
    props: {
      searchIndex: {
        type: String,
        default: ""
      },
    },
    data() {
      return {
        searchValue: "",
      }
    },
    created() {},
    methods: {
      searchTheme() {
        this.$emit("searchFun", {
          index: this.searchIndex,
          value: this.searchValue
        });
      },
    },
  }
</script>

<style>

</style>